import { connect } from 'react-redux'
import CategoryDetail from '../../../views/Detail/CategoryDetail'

function mapStateToProps(state: any) {
    return {
        list: state.detail.list
    }
}

function mapDispatchToProps(dispatch: (obj: any) => void) {
    return {
        'SET_DETAIL_LIST': (data: any, status: number) => {
            dispatch({ type: 'SET_DETAIL_LIST', data, status})
        }
    }
}

export default connect(mapStateToProps, mapDispatchToProps)(CategoryDetail)